package com.alibaba.citrus.cr.forecast.facade.service;

import java.util.List;

import com.alibaba.lattice2.epoch.sdk.model.Result;

import com.epoch.app.crforecastsales.api.forecastsalesenumdataquery.service.ForecastSalesEnumDataQueryService;
import com.epoch.app.crforecastsales.dto.response.DetailStatusResponse;
import com.epoch.app.crforecastsales.dto.response.ForecastOrderTypeResponse;
import com.epoch.app.crforecastsales.dto.response.OrderTicketReasonResponse;
import com.epoch.app.crforecastsales.dto.response.OrderTicketTypeResponse;
import com.epoch.app.crforecastsales.dto.response.RefusedReasonResponse;
import com.epoch.app.crforecastsales.dto.response.SalesOrderTypeResponse;
import com.google.common.collect.Lists;
import org.springframework.stereotype.Service;

/**
 * @author hanguo
 * @date 2021/9/22
 * @Description 预报销售筛选框数据查询
 */
@Service
public class ForecastSalesEnumDataQueryServiceImpl implements ForecastSalesEnumDataQueryService {
    public static final String FORECAST_TAG = "forecastTag";
    public static final String ORDER_TICKET_REASON = "ticketReason";
    public static final String ORDER_REFUSE_REASON = "refuseReason";
    public static final String SALE_ORDER_TAG = "saleOrderTag";
    @Override
    public Result<List<ForecastOrderTypeResponse>> queryForecastOrderTypeList() {

        List<ForecastOrderTypeResponse> list = Lists.newArrayList();
        ForecastOrderTypeResponse forecastOrderTypeResponse = new ForecastOrderTypeResponse();
        forecastOrderTypeResponse.setLabel("标准预报订单");
        forecastOrderTypeResponse.setValue("101");
        list.add(forecastOrderTypeResponse);
        ForecastOrderTypeResponse forecastOrderTypeResponse1 = new ForecastOrderTypeResponse();
        forecastOrderTypeResponse1.setLabel("车销预报订单");
        forecastOrderTypeResponse1.setValue("102");
        list.add(forecastOrderTypeResponse1);
        ForecastOrderTypeResponse forecastOrderTypeResponse2 = new ForecastOrderTypeResponse();
        forecastOrderTypeResponse1.setLabel("补货预报订单");
        forecastOrderTypeResponse1.setValue("103");
        list.add(forecastOrderTypeResponse2);
        ForecastOrderTypeResponse forecastOrderTypeResponse3 = new ForecastOrderTypeResponse();
        forecastOrderTypeResponse1.setLabel("共享仓直发客户预报订单");
        forecastOrderTypeResponse1.setValue("104");
        list.add(forecastOrderTypeResponse3);
        return Result.success(list);
    }

    @Override
    public Result<List<OrderTicketTypeResponse>> queryOrderTicketTypeList() {
        List<OrderTicketTypeResponse> list = Lists.newArrayList();
        for (int i = 1; i < 10; i++) {
            OrderTicketTypeResponse orderTicketTypeResponse = new OrderTicketTypeResponse();
            orderTicketTypeResponse.setLabel("单据类型"+i);
            orderTicketTypeResponse.setValue(i+"");
            list.add(orderTicketTypeResponse);
        }
        return Result.success(list);

    }

    @Override
    public Result<List<OrderTicketReasonResponse>> queryOrderTicketReasonList() {
        List<OrderTicketReasonResponse> list = Lists.newArrayList();
        for (int i = 1; i < 10; i++) {
            OrderTicketReasonResponse orderTicketReasonResponse = new OrderTicketReasonResponse();
            orderTicketReasonResponse.setLabel("单据原因"+i);
            orderTicketReasonResponse.setValue(i+"");
            list.add(orderTicketReasonResponse);
        }
        return Result.success(list);
    }

    @Override
    public Result<List<DetailStatusResponse>> queryDetailStatusList() {
        List<DetailStatusResponse> list = Lists.newArrayList();
        for (int i = 1; i < 10; i++) {
            DetailStatusResponse detailStatusResponse = new DetailStatusResponse();
            detailStatusResponse.setLabel("明细状态"+i);
            detailStatusResponse.setValue(i+"");
            list.add(detailStatusResponse);
        }
        return Result.success(list);
    }

    @Override
    public Result<List<RefusedReasonResponse>> queryRefuseReasonList() {
        List<RefusedReasonResponse> list = Lists.newArrayList();
        for (int i = 1; i < 10; i++) {
            RefusedReasonResponse refusedReasonResponse = new RefusedReasonResponse();
            refusedReasonResponse.setLabel("拒绝原因"+i);
            refusedReasonResponse.setValue(i+"");
            list.add(refusedReasonResponse);
        }
        return Result.success(list);
    }

    @Override
    public Result<List<SalesOrderTypeResponse>> querySaleOrderType() {
        List<SalesOrderTypeResponse> list = Lists.newArrayList();
        for (int i = 1; i < 10; i++) {
            SalesOrderTypeResponse salesOrderTypeResponse = new SalesOrderTypeResponse();
            salesOrderTypeResponse.setLabel("销售订单类型"+i);
            salesOrderTypeResponse.setValue(i+"");
            list.add(salesOrderTypeResponse);
        }
        return Result.success(list);
    }
}
